<%-- 
    Document   : index
    Created on : 5 oct. 2011, 10:57:45
    Author     : Antonin Mozzati & Yanick Schürter
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Tweetor : accueil</title>
        <LINK rel=stylesheet type="text/css" href="style.css">
        <LINK rel=stylesheet type="text/css" href="menu.css">
    </head>

    <body>
	<div id="main">
            <div id="header">
                
                <!-- Login -->
                <jsp:include page="header/login.jsp"/>
                <jsp:include page="header/logo.jsp"/>
                <c:if test="${!empty sessionScope.sessionID}">
                    <jsp:include page="header/menu.jsp"/>
                </c:if>
                    
            </div> <!-- header -->
		
            <c:if test="${empty sessionScope.sessionID}">
                <!-- Inscription -->
                <form name="formulaireInscription" action="subscribe.do" method="post">
                    <table id="subscribe" border="0">
                        <tr>
                            <th colspan="2">Pas encore inscrit sur Tweetor ?</th>
                        </tr>
                        <tr>
                            <td>Login</td>
                            <td><input name="login" type="text" size="20" maxlength="30" /></td>
                        </tr>
                        <tr>
                            <td>Nom</td>
                            <td><input name="nom" type="text" size="20" maxlength="30" /></td>
                        </tr>
                        <tr>
                            <td>Prenom</td>
                            <td><input name="prenom" type="text" size="20" maxlength="30" /></td>
                        </tr>
                        <tr>
                            <td>Adresse e-mail</td>
                            <td><input name="mail" type="text" size="20" maxlength="30" /></td>
                        </tr>
                        <tr>
                            <td>Mot de passe</td>
                            <td><input name="pass1" type="password" size="20" /></td>
                        </tr>
                        <tr>
                            <td>Confirmer mot de passe</td>
                            <td><input name="pass2" type="password" size="20" /></td>
                        </tr>
                        <tr>
                            <td colspan="2" align="right">
                                <input type="hidden" name="action" value="inscription" />
                                <input name="inscription" type="submit" value="S'inscrire" />
                            </td>
                        </tr>
                    </table>
                </form> <!-- formulaireInscription -->
            </c:if>
	    
	    <!-- afficher erreur -->
            <c:if test="${!empty requestScope.erreur}">
		<div id="erreur">
		    <c:out value="${requestScope.erreur}" />
		</div>
	    </c:if>
            
	</div> <!-- main -->
	
    </body>
</html>
